Stereoscopic three-dimensional (3D) effects may be obtained through anaglyph images viewed with appropriate 3D anaglyph glasses. Each lens of the 3D anaglyph glasses may be of a color chromatically opposite to that of the other lens. For example, the chromatically opposite colors may be red and blue. In an anaglyph image, two mildly differing perspectives of the same subject may be superimposed on one another in the aforementioned chromatically opposite colors. The two color layers may be offset with respect to each other to produce a depth effect. The main subject may be in the center, while the foreground and the background may be shifted laterally in opposite directions.
For example, when viewing an anaglyph through appropriate 3D anaglyph glasses, the left eye may perceive the true white or true black areas of the anaglyph image the same way as the right eye, whose corresponding lens is of a chromatically opposite color to that of the left eye lens. The left eye, when covered by the red filter, may perceive the red and blue parts of the image as “white” and “black” respectively, and the opposite effect may be perceived by the right eye.
A method of producing monochromatic/grayscale anaglyph images from an input stereo pair of colored images may include converting the stereo pair to grayscale and then obtaining the final anaglyph image by using the red channel of the left grayscale image and the green and blue channels of the right grayscale image. A method of producing color anaglyph images may include combining the red channel of the left color image and the green and blue channels of the right color image to obtain the final anaglyph image. No intermediate grayscale production may be required.
The problems associated with regular color anaglyph images generated using the aforementioned method may include saturated colors not being portrayed well, certain color intensities and hues (e.g., bright red and blue) causing eye strain after sustained use, color leaks between the left eye and the right eye, brightness and contrast differences between the left and right images, discomfort caused by retinal rivalry, and ghosting due to the color leaks. Ghosting may cause an unintended portion of the image destined for one eye to be seen by the other eye.
Methods to alleviate the abovementioned problems associated with the typical method of anaglyph image generation may include utilizing grayscale anaglyph images, half-color anaglyph images, and/or optimized anaglyph images. Utilizing grayscale images alone may lead to less eye strain and retinal rivalry. However, they may trade color for comfort. Half-color anaglyph images utilize grayscale images for the left eye and blue and green images for the right eye. However, they reduce retinal rivalry at the expense of, again, color. Generating optimized anaglyph images may involve leaving most of the red channel from the original image unutilized. This may eliminate retinal rivalry at the expense of having no red colors (i.e., reduced color).